<script type="text/javascript" >
    AppComm.include.load("#url('/static/js/util/verify.js')","js");
    AppComm.include.load("#url('/static/comm/ztree/css/zTreeStyle/zTreeStyle.css')", "css");
    AppComm.include.load("#url('/static/comm/ztree/js/jquery.ztree.all.js')", "js");
    AppComm.include.load("#url('/static/js/user/roleManagement.js')","js");
    AppComm.include.load("#url('/static/js/common/commonZtree.js')","js");
</script>

<div class="animated fadeIn">
    <div style="text-align: left;">
        <span class="layui-breadcrumb">
                <a href="">系统管理</a>
                <a><cite>角色管理</cite></a>
        </span>
    </div>
    <hr>
    <div class="roleManager_box"></div>
</div>
<script id="roleManagerList_template" type="text/html">
    <div style="text-align: left;">
        <form class="layui-form" lay-filter="searchForm" action="">
            <div class="layui-inline">
                <!--<label class="layui-form-label">关键字</label>-->
                <div class="layui-input-inline">
                    <input name="nameInput" type="text" placeholder="角色名称" class="layui-input" style="width:200px;">
                </div>
            </div>
            <div class="layui-inline">
                &nbsp;&nbsp;
                <button class="layui-btn layui-btn-normal" lay-submit lay-filter="searchBtn">查询</button>
                <button class="layui-btn layui-btn-normal" id="addBtn">添加</button>
            </div>
        </form>
    </div>

    <div style="margin-right: 10px;">
        <table id="tb_list" lay-filter="tb_list"></table>
    </div>
</script>

<script type="text/html" id="toolbar">
    <a class="layui-btn layui-btn-xs" lay-event="editBtn">编辑</a>
    <a class="layui-btn layui-btn-xs" lay-event="menuBtn">菜单授权</a>
    <a class="layui-btn layui-btn-xs" lay-event="operateBtn">操作授权</a>
    <a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="deleteBtn">删除</a>
</script>

<script id="roleManagerForm_template" type="text/html">
    <form class="layui-form" action="">
    <div class="layui-tab-item layui-show" style="width:692px;margin: 0 auto;">
    <input type="hidden" id="id" value="{{id}}" lay-verify="id">
        <div class="layui-form-item">
            <div class="layui-inline" id="roleKey_div">
                <label class="layui-form-label">角色关键字</label>
                <div class="layui-input-inline">
                    <input type="text" id="roleKey" name="roleKey" required  lay-verify="roleKey" placeholder="请输入角色关键字" autocomplete="off" class="layui-input" value="{{roleKey}}">
                </div>
            </div>
            <div class="layui-inline">
                <label class="layui-form-label">角色名称</label>
                <div class="layui-input-inline">
                    <input type="text" id="roleName" name="roleName" required  lay-verify="required" placeholder="请输入角色名称" autocomplete="off" class="layui-input" value="{{roleName}}">
                </div>
            </div>
        </div>
        <div class="layui-form-item">
            <div class="layui-inline">
                <label class="layui-form-label">序号</label>
                <div class="layui-input-inline">
                    <input style="width:512px;" type="text" id="orderId" name="orderId" lay-verify="orderId" placeholder="请输入序号" autocomplete="off" class="layui-input" value="{{orderId}}" >
                </div>
            </div>
        </div>
        <div class="layui-form-item">
            <div class="layui-inline">
                <label class="layui-form-label">说明</label>
                <div class="layui-input-inline">
                    <textarea style="width: 512px;" placeholder="请输入内容" id="comment" name="comment" lay-verify="comment" class="layui-textarea"></textarea>
                </div>
            </div>
        </div>
    <br>
     <div class="layui-form-item">
        <div class="layui-inline" style="margin-left: 225px;width:182px;">
            <button class="layui-btn layui-btn-normal" lay-submit="" id="saveBtn" lay-filter="submitBtn">提交</button>
            <button class="layui-btn layui-btn-normal" id="cancelBtn">取消</button>
        </div>
    </div>
    </div>
    </form>
</script>

<!--菜单授权页-->
<script id="roleManagerForm_ztree" type="text/html">
<div style="margin-left: 24px;">
    <input type="hidden" id="dataId" value="{{dataId}}" >
    <ul id="treeDemo" class="ztree"></ul>
</div>
</script>
<!--操作授权页-->
<script id="roleManagerList_operation" type="text/html">
    <div id="opLog" style="margin: 10px;">
    </div>
    <div style="text-align: left;margin: 10px;">
        <form class="layui-form" lay-filter="searchOpForm" action="">
            <div class="layui-inline">
                <div class="layui-input-inline">
                    <input name="operationName" type="text" placeholder="操作名称" class="layui-input" style="width:200px;">
                </div>
            </div>
            <div class="layui-inline">
                &nbsp;&nbsp;
                <button class="layui-btn layui-btn-normal" lay-submit lay-filter="searchOp">查询</button>
                <button class="layui-btn layui-btn-normal" id="getCheckData" data-type="getCheckData">提交</button>
            </div>
        </form>
    </div>

    <div style="margin: 10px;">
        <table id="op_list" lay-filter="op_list" ></table>
    </div>
</script>